package org.dlsu.mt.parser;
import org.dlsu.mt.DictionaryInterface;
import org.dlsu.mt.MorphInterface;

/**
 * This an interface for implementations of Lexical Analyzers for use with the NLPParser.
 * Requires that the analyze() method be implemented and return a LexerInterface, which is a
 * set of lexical items or tokens produced from a given string.
 */
public interface LexicalAnalyzerInterface {

	/**
	 * Produces a list of tokens and returned as a LexerInterface from a given string
	 *
	 * @param text The string to analyze/tokenize
	 * @return The set of analyzed tokens
	 */
	public LexerInterface analyze(Object text) throws Exception;
	/**
	 * Sets the dictionary to be used by the lexical analyzer
	 *
	 * @param dict Dictionary to be used
	 */
	public void setDictionary(DictionaryInterface dict);
	/**
	 * Sets the morphological analyzer to be used by the lexical analyzer
	 *
	 * @param dict Morphological Analyzer to be used
	 */
	public void setMorph(MorphInterface morph);
}